package cn.wizzer.app.user.modules.models;

import cn.wizzer.framework.base.model.BaseModel;
import lombok.Data;
import org.nutz.dao.entity.annotation.*;
import org.nutz.dao.interceptor.annotation.PrevInsert;
import org.nutz.integration.json4excel.annotation.J4EIgnore;

/**
 * 体验金
 */
@Data
@Table("trial_fund")
public class TrialFund extends BaseModel {

    @Column
    @Name
    @Comment("ID")
    @J4EIgnore
    @ColDefine(type = ColType.VARCHAR, width = 32)
    @PrevInsert(uu32 = true)
    private String id;

    @Comment("用户id")
    @Column
    @ColDefine(type = ColType.VARCHAR, width = 32)
    private String userId;

    @Comment("ip")
    @Column
    @ColDefine(type = ColType.VARCHAR, width = 32)
    private String ip;


    @Column
    @Comment("单号")
    @ColDefine(type = ColType.VARCHAR, width = 32)
    private String no;

    @Column
    @Comment("是否收回体验金")
    @Default("0")
    @ColDefine(type = ColType.BOOLEAN)
    private Boolean track;

    @Column
    @Comment("体验金收益超过30天是否处理")
    @Default("0")
    @ColDefine(type = ColType.BOOLEAN)
    private Boolean profit30;

    @Column
    @Comment("创建时间")
    @PrevInsert(els = @EL("$me.now()"))
    private Long ctAt;

}
